github_user should override namespace.name for legacy roles. #1923
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
there are 5408 roles on old galaxy where the github_user doesn't match the role's namespace name
So when you install laniakea.galaxy, the role found via
?owner_username=laniakea&name=galaxy
is http://old-galaxy.ansible.com/api/v1/roles/51041/ ... which has a github_user key with value Laniakea-elixir-itThe way that worked was the role model linked to a repository model and the repository model linked to a provider namespace model ... the provider namespace's "name" property is what the role serializer emits for github_user
I'm not sure what this means for future imports of the roles considering the authors need to provide the proper org|user name to the CLI ... so I'll have to do some testing on that.
After this fix is deployed, we'll have to inject the missing field into all of the relevant roles' full_metadata column.